xen: fix hvm_domain_use_pirq's behavior
authorStefano Stabellini <stefano.stabellini@eu.citrix.com>
Wed, 31 Aug 2011 14:23:12 +0000 (15:23 +0100)
committerStefano Stabellini <stefano.stabellini@eu.citrix.com>
Wed, 31 Aug 2011 14:23:12 +0000 (15:23 +0100)
commit79858fee307c1b47eef66a0c280d23b650e8d906
treebb314b7b18c3af053053287003363778d3ee4c88
parent12b6ea528fd6048bebcaee852d1b6be811907be3
xen: fix hvm_domain_use_pirq's behavior

hvm_domain_use_pirq should return true when the guest is using a
certain pirq, no matter if the corresponding event channel is
currently enabled or disabled.  As an additional complication, qemu is
going to request pirqs for passthrough devices even for Xen unaware
HVM guests, so we need to wait for an event channel to be connected
before considering the pirq of a passthrough device as "in use".

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
xen/arch/x86/irq.c
xen/arch/x86/physdev.c
xen/common/event_channel.c